package basic;

public class ArrayDemo3 {
    public static void main(String[] args) {
        char[] charArr = {'I','m','o','o','c'};
        char lastElement = charArr[charArr.length-1];
//        lastElement是最后一个元素
        System.out.println("charArr数组的最后一个元素为：" + lastElement);
    }
}
